package com.hkd.cya.命令模式;

public class Teacher {
    private Command command1,command2;

    public Teacher(Command command1, Command command2) {
        this.command1 = command1;
        this.command2 = command2;
    }
    public void task1(){
        System.out.println("--------辅导员的任务1：找学生参加学科类竞赛--------");
        command1.excute();
    }
    public void task2(){
        System.out.println("--------辅导员的任务2：找学生参加体育类竞赛--------");
        command2.excute();
    }
}
